/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 *//*

package cz.worsik.android.test.rideshare.util.listener;

import android.view.View;
import cz.worsik.android.test.rideshare.MainActivity;
import cz.worsik.android.test.rideshare.model.BooleanMesssage;

public class DeleteContactListener implements View.OnClickListener 
{
	// musi se pricist k startovnimu ID
	public String name;
	MainActivity a;

	public DeleteContactListener(MainActivity a, String name)
	{
		this.name = name;
		this.a = a;
	}

	public void onClick(View v) 
	{
		//showToast("Smažu kontakt se jménem "+name, false);

		a.getDb().open();
		BooleanMesssage deleted = a.getDb().deleteDriver(name, true);
		a.getDb().close();

		a.showToast(deleted.getMsg());

		if (deleted.isOK()) {
			a.generateSettings();
		}

		a.popup_window.dismiss();
	}
}
*/
